package com.dd.demo.day8;

public class Student {
    private int id;
    private String name;
    private int age;
    static String room;
    private static int idCounter = 0;
    public Student(){
        idCounter++;

    }
    public Student(String name, int age){
        this.name=name;
        this.age=age;
        this.id=++idCounter;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }



    public String getName(){
        return name;
    }

    public int getAge() {
        return age;
    }
}
